import { Message } from "element-ui";

const errorHandle = (err) => {
    switch (err.response.status) {
        case 404:
            Message.error('No resource was found')
            break;
        case 500:
            Message.error('Server Error')
            break;
        default:
            Message.error('Unknown Error')
    }
};

export default errorHandle;